/*
 * @Author: 詹真琦(legendryztachi@gmail.com)
 * @Date: 2022-01-20 16:13:24
 * @LastEditors: 詹真琦(legendryztachi@gmail.com)
 * @LastEditTime: 2022-05-11 11:07:02
 * @FilePath: \code\cwp-front\pc-collaboration\src\handles\handle-list\summary\modules\specifies-return.js
 * @Description: 指定回退
 */
import { returnFunction } from './return';

/**
 * @description: 手动构建 指定回退按钮 参数
 * @param {NUmber} submitStyle 回退类型 0:流程重走、1:提交给我
 * @return {*}
 */
export function createSpecifiesReturnBtn(submitStyle = 1) {
    return {
        label: this.$i18n('collaboration.substate.16.label'),
        handle: 'specifiesReturn',
        handleOriginal: 'SpecifiesReturn',
        submitStyle,
    };
}

export default function (btn) {
    return new Promise((resolve) => {
        returnFunction.call(this, btn);
        resolve();
    });
}
